home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-09-17 | 2.1 KB | 60 lines | [TEXT/MPS ] |
- //========================================================================================
- //
- // File: FWAMnuIt.cpp
- // Release Version: $ ODF 2 $
- //
- // Copyright: (c) 1993 - 1996 by Apple Computer, Inc., all rights reserved.
- //
- //========================================================================================
- // We separate the archiving functions into their own translation units in order to
- // enable dead-stripping.
-
- #include "FWOS.hpp"
-
- #ifndef FWMNUITM_H
- #include "FWMnuItm.h"
- #endif
-
- //========================================================================================
- // File scope definitions
- //========================================================================================
-
- #ifdef FW_BUILD_MAC
- #pragma segment fwmenu
- #endif
-
- //========================================================================================
- // class FW_CMenuItem
- //========================================================================================
-
- const FW_ClassTypeConstant FW_LMenuItem = FW_TYPE_CONSTANT('m','n','i','t');
- FW_REGISTER_ARCHIVABLE_CLASS(FW_LMenuItem, FW_CMenuItem, FW_CMenuItem::Read, 0, 0, FW_CMenuItem::Write)
-
- //----------------------------------------------------------------------------------------
- // FW_CMenuItem::Read
- //----------------------------------------------------------------------------------------
- // Maybe it would be better to simply not define this function at all, and pass 0 to
- // FW_REGISTER_ARCHIVABLE_CLASS above.
-
- void* FW_CMenuItem::Read(FW_CReadableStream& stream, FW_ClassTypeConstant type)
- {
- FW_UNUSED(stream);
- FW_UNUSED(type);
-
- FW_DEBUG_MESSAGE("FW_CMenuItem::Read should never have been called");
- return NULL;
- }
-
- //----------------------------------------------------------------------------------------
- // FW_CMenuItem::Write
- //----------------------------------------------------------------------------------------
-
- void FW_CMenuItem::Write(FW_CWritableStream& stream, FW_ClassTypeConstant type, const void *object)
- {
- FW_UNUSED(type);
- FW_SOMEnvironment ev;
- FW_CMenuItem* menuItem = (FW_CMenuItem*)object;
- menuItem->Flatten(ev, stream);
- }
-
-